<!DOCTYPE html>

<html lang="en">
<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width">
	<title>WolMap Class: MapViewer</title>

	<!--[if lt IE 9]>
	<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
	<![endif]-->
	<link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">

	<link type="text/css" rel="stylesheet" href="styles/site.cosmo.css">

</head>

<body>

<div class="navbar navbar-default navbar-fixed-top navbar-inverse">
<div class="container">
	<div class="navbar-header">
		<a class="navbar-brand" href="index.html"><img class="branding-logo" src="logo.png"
		alt="logo"/>WolMap</a>
		<button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation">
			<span class="icon-bar"></span>
			<span class="icon-bar"></span>
			<span class="icon-bar"></span>
        </button>
	</div>
	<div class="navbar-collapse collapse" id="topNavigation">
		<ul class="nav navbar-nav">
			
			<li class="dropdown">
				<a href="namespaces.list.html" class="dropdown-toggle" data-toggle="dropdown">Namespaces<b class="caret"></b></a>
				<ul class="dropdown-menu ">
					<li><a href="DragHandler.html">DragHandler</a></li><li><a href="wol.html">wol</a></li><li><a href="wol.util.html">wol.util</a></li>
				</ul>
			</li>
			
			<li class="dropdown">
				<a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a>
				<ul class="dropdown-menu ">
					<li><a href="wol.LayerManager.html">wol.LayerManager</a></li><li><a href="wol.Locator.html">wol.Locator</a></li><li><a href="wol.MapViewer.html">wol.MapViewer</a></li><li><a href="wol.Tracer.html">wol.Tracer</a></li>
				</ul>
			</li>
			
		</ul>
        
            <div class="col-sm-3 col-md-3">
                <form class="navbar-form" role="search">
                    <div class="input-group">
                        <input type="text" class="form-control" placeholder="Search" name="q" id="search-input">
                        <div class="input-group-btn">
                            <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button>
                        </div>
                    </div>
                </form>
            </div>
        
	</div>

</div>
</div>


<div class="container" id="toc-content">
<div class="row">

	
	<div class="col-md-8">
	
		<div id="main">
			

	<h1 class="page-title">Class: MapViewer</h1>
<section>

<header>
    
        <h2>
            <span class="ancestors"><a href="wol.html">wol</a>.</span>
        
        MapViewer
        </h2>
        
    
</header>


<article>
    <div class="container-overview">
    
        
<hr>
<dt>
    <h4 class="name" id="MapViewer"><span class="type-signature"></span>new MapViewer<span class="signature">(id, option)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>wol地图</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>id</code></td>
            

            <td class="type">
            
                
<span class="param-type">string</span>



            
            </td>

            

            

            <td class="description last"><p>DOM元素id</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>option</code></td>
            

            <td class="type">
            
                
<span class="param-type">object</span>



            
            </td>

            

            

            <td class="description last"><p>配置项</p>
                <h6 class="method-params-label method-subparams-label">Properties</h6>
                

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>projection</code></td>
            

            <td class="type">
            
                
<span class="param-type">string</span>



            
            </td>

            

            

            <td class="description last"><p>投影坐标系</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>center</code></td>
            

            <td class="type">
            
                
<span class="param-type">Array</span>



            
            </td>

            

            

            <td class="description last"><p>视图中心位置，默认为 [13059385.715379057, 4734320.828070238]</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>extent</code></td>
            

            <td class="type">
            
                
<span class="param-type">Array</span>



            
            </td>

            

            

            <td class="description last"><p>视图范围</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>layers</code></td>
            

            <td class="type">
            
                
<span class="param-type">Array</span>



            
            </td>

            

            

            <td class="description last"><p>图层配置，通过传入一至多个配置项创建图层，每个配置项须包含图层类型(type)，图层名称(name)，地图服务地址(url)等必要参数；图层类型可选值为'Vector'、'Cluster'、'Mask'、'XYZ'、'WMS'，<br>
图层类型为'XYZ'或'WMS'时需指定地图服务地址；配置项中其他参数设置请参见<a href="wol.util.html#.createVectorLayer">wol.util.createVectorLayer</a>、<a href="wol.util.html#.createClusterLayer">wol.util.createClusterLayer</a>、<a href="wol.util.html#.createMaskLayer">wol.util.createMaskLayer</a>、<a href="wol.util.html#.createXYZLayer">wol.util.createXYZLayer</a>、<a href="wol.util.html#.createWMSLayer">wol.util.createWMSLayer</a>、</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>zoom</code></td>
            

            <td class="type">
            
                
<span class="param-type">number</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>当前缩放类型，默认为 undefiend</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>minZoom</code></td>
            

            <td class="type">
            
                
<span class="param-type">number</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>地图最小缩放级别，默认为 undefiend</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>maxZoom</code></td>
            

            <td class="type">
            
                
<span class="param-type">number</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>地图最大缩放级别，默认为 undefiend</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>controls</code></td>
            

            <td class="type">
            
                
<span class="param-type">object</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>地图控件配置</p>
                <h6 class="method-params-label method-subparams-label">Properties</h6>
                

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>zoom</code></td>
            

            <td class="type">
            
                
<span class="param-type">boolean</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>是否显示地图缩放控件，默认为 true</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>scaleLine</code></td>
            

            <td class="type">
            
                
<span class="param-type">boolean</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>是否显示比例尺控件，默认为 true</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>overviewMap</code></td>
            

            <td class="type">
            
                
<span class="param-type">boolean</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>是否显示鹰眼控件，默认为 false</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>fullScreen</code></td>
            

            <td class="type">
            
                
<span class="param-type">boolean</span>
|

<span class="param-type">undefined</span>



            
            </td>

            

            

            <td class="description last"><p>是否显示全屏控件，默认为 false</p></td>
        </tr>

    
    </tbody>
</table>

            </td>
        </tr>

    
    </tbody>
</table>

            </td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-29">line 29</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    
    <h5>Requires:</h5>
    <ul>
        <li>module:wol-util.js</li>
    </ul>
    

    

    

    

    

    

    
</dd>

    
    </div>

    

    
        <h3 class="subsection-title">Requires</h3>

        <ul>
            <li>module:wol-util.js</li>
        </ul>
    

    

    

    

    
        <h3 class="subsection-title">Members</h3>

        <dl>
            
<hr>
<dt class="name" id="callback">
    <h4 id="callback"><span class="type-signature"></span>callback<span class="type-signature"></span></h4>

    
</dt>
<dd>
    
    <div class="description">
        <p>回调函数</p>
    </div>
    

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-76">line 76</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    
</dd>

        </dl>
    

    
        <h3 class="subsection-title">Methods</h3>

        <dl>
            
<hr>
<dt>
    <h4 class="name" id="addLayer"><span class="type-signature"></span>addLayer<span class="signature">(layer)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>添加图层</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>layer</code></td>
            

            <td class="type">
            
                
<span class="param-type">ol.layer.Base</span>



            
            </td>

            

            

            <td class="description last"><p>图层对象</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-159">line 159</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="addLayers"><span class="type-signature"></span>addLayers<span class="signature">(layers)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>添加多个图层</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>layers</code></td>
            

            <td class="type">
            
                
<span class="param-type">Array.&lt;ol.layer.Base></span>



            
            </td>

            

            

            <td class="description last"><p>图层对象数组</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-179">line 179</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="extentAt"><span class="type-signature"></span>extentAt<span class="signature">(target, duration, padding)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>缩放视图至指定范围</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>target</code></td>
            

            <td class="type">
            
                
<span class="param-type">ol.Extent</span>
|

<span class="param-type">ol.geom.Geometry</span>



            
            </td>

            

            

            <td class="description last"><p>目标视图范围</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>duration</code></td>
            

            <td class="type">
            
                
<span class="param-type">number</span>



            
            </td>

            

            

            <td class="description last"><p>动画持续时间，可选参数，默认为0</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>padding</code></td>
            

            <td class="type">
            
                
<span class="param-type">number</span>
|

<span class="param-type">Array</span>



            
            </td>

            

            

            <td class="description last"><p>目标视图周围间距</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-245">line 245</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="getCurZIndex"><span class="type-signature"></span>getCurZIndex<span class="signature">()</span><span class="type-signature"> &rarr; {number}</span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>获取图层序号值</p>
    </div>
    

    

    

    
        <h5>This:</h5>
        <ul><li><a href="wol.MapViewer.html">wol.MapViewer</a></li></ul>
    
    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-92">line 92</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    
    <h5>Returns:</h5>
    
            


<dl>
    <dt>
        Type
    </dt>
    <dd>
        
<span class="param-type">number</span>



    </dd>
</dl>


        

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="getLayerByName"><span class="type-signature"></span>getLayerByName<span class="signature">(name)</span><span class="type-signature"> &rarr; {ol.layer.Base}</span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>根据图层名称获取图层</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>name</code></td>
            

            <td class="type">
            
                
<span class="param-type">string</span>



            
            </td>

            

            

            <td class="description last"><p>图层名称</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-142">line 142</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    
    <h5>Returns:</h5>
    
            
<div class="param-desc">
    <ul>
<li>图层对象</li>
</ul>
</div>



<dl>
    <dt>
        Type
    </dt>
    <dd>
        
<span class="param-type">ol.layer.Base</span>



    </dd>
</dl>


        

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="getLayers"><span class="type-signature"></span>getLayers<span class="signature">()</span><span class="type-signature"> &rarr; {ol.Collection}</span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>获取图层集合</p>
    </div>
    

    

    

    
    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-133">line 133</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    
    <h5>Returns:</h5>
    
            
<div class="param-desc">
    <ul>
<li>ol集合对象</li>
</ul>
</div>



<dl>
    <dt>
        Type
    </dt>
    <dd>
        
<span class="param-type">ol.Collection</span>



    </dd>
</dl>


        

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="getMap"><span class="type-signature"></span>getMap<span class="signature">()</span><span class="type-signature"> &rarr; {ol.Map}</span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>获取地图实例</p>
    </div>
    

    

    

    
        <h5>This:</h5>
        <ul><li><a href="wol.MapViewer.html">wol.MapViewer</a></li></ul>
    
    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-83">line 83</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    
    <h5>Returns:</h5>
    
            


<dl>
    <dt>
        Type
    </dt>
    <dd>
        
<span class="param-type">ol.Map</span>



    </dd>
</dl>


        

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="getView"><span class="type-signature"></span>getView<span class="signature">()</span><span class="type-signature"> &rarr; {ol.View}</span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>获取视图实例</p>
    </div>
    

    

    

    
    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-125">line 125</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    
    <h5>Returns:</h5>
    
            
<div class="param-desc">
    <ul>
<li>地图对象</li>
</ul>
</div>



<dl>
    <dt>
        Type
    </dt>
    <dd>
        
<span class="param-type">ol.View</span>



    </dd>
</dl>


        

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="panTo"><span class="type-signature"></span>panTo<span class="signature">(target, duration)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>平移视图中心点至某一坐标点或某一要素</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>target</code></td>
            

            <td class="type">
            
                
<span class="param-type">ol.Coordinate</span>
|

<span class="param-type">ol.Feature</span>



            
            </td>

            

            

            <td class="description last"><p>目标坐标点或目标要素</p></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>duration</code></td>
            

            <td class="type">
            
                
<span class="param-type">number</span>



            
            </td>

            

            

            <td class="description last"><p>动画持续时间，可选参数，默认为0</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-221">line 221</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="register"><span class="type-signature"></span>register<span class="signature">(evtType, handler)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>事件注册，目前仅支持'addLayer'和'removeLayer'事件</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>evtType</code></td>
            

            <td class="type">
            
            </td>

            

            

            <td class="description last"></td>
        </tr>

    

        <tr>
            
                <td class="name"><code>handler</code></td>
            

            <td class="type">
            
            </td>

            

            

            <td class="description last"></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-116">line 116</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="removeLayer"><span class="type-signature"></span>removeLayer<span class="signature">(layer)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>删除图层</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>layer</code></td>
            

            <td class="type">
            
                
<span class="param-type">ol.layer.Base</span>



            
            </td>

            

            

            <td class="description last"><p>图层对象</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-189">line 189</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="removeLayerByName"><span class="type-signature"></span>removeLayerByName<span class="signature">(name)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>根据图层名称删除图层</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>name</code></td>
            

            <td class="type">
            
                
<span class="param-type">string</span>



            
            </td>

            

            

            <td class="description last"><p>图层名称</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-212">line 212</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="removeLayers"><span class="type-signature"></span>removeLayers<span class="signature">(layers)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>删除多个图层</p>
    </div>
    

    

    

    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>layers</code></td>
            

            <td class="type">
            
                
<span class="param-type">Array.&lt;ol.layer.Base></span>



            
            </td>

            

            

            <td class="description last"><p>图层对象数组</p></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-202">line 202</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        
            
<hr>
<dt>
    <h4 class="name" id="setCurZIndex"><span class="type-signature"></span>setCurZIndex<span class="signature">(curZIndex)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>

    
    <div class="description">
        <p>设置图层序号值</p>
    </div>
    

    

    

    
        <h5>This:</h5>
        <ul><li><a href="wol.MapViewer.html">wol.MapViewer</a></li></ul>
    
    
        <h5>Parameters:</h5>
        

<table class="params table table-striped">
    <thead>
    <tr>
        
        <th>Name</th>
        

        <th>Type</th>

        

        

        <th class="last">Description</th>
    </tr>
    </thead>

    <tbody>
    

        <tr>
            
                <td class="name"><code>curZIndex</code></td>
            

            <td class="type">
            
                
<span class="param-type">number</span>



            
            </td>

            

            

            <td class="description last"></td>
        </tr>

    
    </tbody>
</table>

    

    
<dl class="details">
    

	

	

	

    

    

    

    

	

	

	

	

	



	
	<dt class="tag-source method-doc-label method-doc-details-label">Source:</dt>
	<dd class="tag-source">
		<ul class="dummy">
			<li>
				<a href="wol-viewer.js.html">wol-viewer.js</a>,
				 <a href="wol-viewer.js.html#sunlight-1-line-101">line 101</a>
			</li>
		</ul>
	</dd>
	

	

	

	
</dl>


    

    

    

    

    

    

    
</dd>

        </dl>
    

    

    
</article>

</section>




		</div>
	</div>

	<div class="clearfix"></div>

	
		<div class="col-md-3">
			<div id="toc" class="col-md-3 hidden-xs hidden-sm hidden-md"></div>
		</div>
	

</div>
</div>


    <div class="modal fade" id="searchResults">
      <div class="modal-dialog">
        <div class="modal-content">
          <div class="modal-header">
            <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
            <h4 class="modal-title">Search results</h4>
          </div>
          <div class="modal-body"></div>
          <div class="modal-footer">
            <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
          </div>
        </div><!-- /.modal-content -->
      </div><!-- /.modal-dialog -->
    </div>


<footer>


	<span class="copyright">
	©2020 Aegean
	</span>

<span class="jsdoc-message">
	Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.3</a>
	
		on Sat Mar 14th 2020
	
	using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>.
</span>
</footer>

<script src="scripts/docstrap.lib.js"></script>
<script src="scripts/toc.js"></script>

    <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script>


<script>
$( function () {
	$( "[id*='$']" ).each( function () {
		var $this = $( this );

		$this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
	} );

	$( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () {
		var $this = $( this );

		var example = $this.find( "code" );
		exampleText = example.html();
		var lang = /{@lang (.*?)}/.exec( exampleText );
		if ( lang && lang[1] ) {
			exampleText = exampleText.replace( lang[0], "" );
			example.html( exampleText );
			lang = lang[1];
		} else {
			var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/);
			lang = langClassMatch ? langClassMatch[1] : "javascript";
		}

		if ( lang ) {

			$this
			.addClass( "sunlight-highlight-" + lang )
			.addClass( "linenums" )
			.html( example.html() );

		}
	} );

	Sunlight.highlightAll( {
		lineNumbers : true,
		showMenu : true,
		enableDoclinks : true
	} );

	$.catchAnchorLinks( {
        navbarOffset: 10
	} );
	$( "#toc" ).toc( {
		anchorName  : function ( i, heading, prefix ) {
			return $( heading ).attr( "id" ) || ( prefix + i );
		},
		selectors   : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4",
		showAndHide : false,
		smoothScrolling: true
	} );

	$( "#main span[id^='toc']" ).addClass( "toc-shim" );
	$( '.dropdown-toggle' ).dropdown();

    $( "table" ).each( function () {
      var $this = $( this );
      $this.addClass('table');
    } );

} );
</script>



<!--Navigation and Symbol Display-->


<!--Google Analytics-->



    <script type="text/javascript">
        $(document).ready(function() {
            SearcherDisplay.init();
        });
    </script>


</body>
</html>